<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org">
    <head>
        <th:block th:include="include :: header('新增用户')"/>
    </head>
    <body>
        <div class="main-content">
            <form class="form-horizontal" id="form-user-add">
                <div class="row">
                    <div class="col-sm-6">
                        <div class="form-group">
                            <label class="col-sm-4 control-label is-required">用户名称：</label>
                            <div class="col-sm-8">
                                <input class="form-control" name="userName" placeholder="请输入用户名称" type="text">
                            </div>
                        </div>
                    </div>
                    <div class="col-sm-6">
                        <div class="form-group">
                            <label class="col-sm-4 control-label is-required">归属部门：</label>
                            <div class="col-sm-8">
                                <div class="input-group">
                                    <input class="form-control" name="deptName" placeholder="请选择归属部门"
                                           type="text">
                                    <span class="input-group-addon"><i class="fa fa-search"></i></span>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>
                <div class="row">
                    <div class="col-sm-6">
                        <div class="form-group">
                            <label class="col-sm-4 control-label is-required">手机号码：</label>
                            <div class="col-sm-8">
                                <input class="form-control" name="phonenumber" placeholder="请输入手机号码" type="text">
                            </div>
                        </div>
                    </div>
                    <div class="col-sm-6">
                        <div class="form-group">
                            <label class="col-sm-4 control-label is-required">邮箱：</label>
                            <div class="col-sm-8">
                                <input class="form-control" name="email" placeholder="请输入邮箱" type="text">
                            </div>
                        </div>
                    </div>
                </div>
                <div class="row">
                    <div class="col-sm-6">
                        <div class="form-group">
                            <label class="col-sm-4 control-label is-required">登录账号：</label>
                            <div class="col-sm-8">
                                <input class="form-control" name="loginName" placeholder="请输入登录账号" type="text">
                            </div>
                        </div>
                    </div>
                    <div class="col-sm-6">
                        <div class="form-group">
                            <label class="col-sm-4 control-label is-required">登录密码：</label>
                            <div class="col-sm-8">
                                <input class="form-control" name="password" placeholder="请输入登录密码"
                                       type="password">
                            </div>
                        </div>
                    </div>
                </div>
                <div class="row">
                    <div class="col-sm-6">
                        <div class="form-group">
                            <label class="col-sm-4 control-label">用户性别：</label>
                            <div class="col-sm-8">
                                <div class="input-group" style="width: 100%">
                                    <select class="form-control m-b" name="sex"
                                            th:with="type=${@dict.getType('sys_user_sex')}">
                                        <option th:each="dict : ${type}" th:text="${dict.dictLabel}"
                                                th:value="${dict.dictValue}"></option>
                                    </select>
                                </div>
                            </div>
                        </div>
                    </div>
                    <div class="col-sm-6">
                        <div class="form-group">
                            <label class="col-sm-4 control-label">用户状态：</label>
                            <div class="col-sm-8">
                                <label class="toggle-switch switch-solid">
                                    <input checked id="status" type="checkbox">
                                    <span></span>
                                </label>
                            </div>
                        </div>
                    </div>
                </div>
            </form>
        </div>
        <th:block th:include="include :: footer"/>
        <script type="text/javascript">
            function submitHandler() {
                if ($.validate.form()) {
                    $.modal.msgSuccess('保存成功！');
                }
            }
        </script>
    </body>
</html>
